<%@ page  contentType="text/html; charset=UTF-8"%>
<%@ include file="../../public/public.jsp" %>

<% int rowColor = 1; 
	int pageSize = ((Integer)valueStack.findValue("pageForm.pageSize")).intValue();
	int pageNo = ((Integer)valueStack.findValue("pageForm.pageNo")).intValue();
	int rowNo = (pageNo-1)*pageSize+1;
%>
    <table  cellspacing="1" class="dataTableStyle"> 
    	<thead>
    	<s:if test="pagePosition.toLowerCase().equals('top') || pagePosition.toLowerCase().equals('all')">
    		<tr bgcolor="#FFFFFF">
    		
    			<td colspan="20">
    				<ss:page value="pageForm"></ss:page>
    			</td>
    		</tr>
    		</s:if>
    		<tr>
    			<th align="center" width=5%">序号</th>
    			<th align="center" width="30%">软件名称</th>
    			<th align="center" width="15%">完成人</th>
    			<th align="center" width="15%">著作权人</th>
    			<th align="center" width="10%">提交时间</th>
    			<ss:condition rescode="SoftwareApply" optcode="PRINT||GLOBAL">
    			<th align="center" width="15%">报送单位</th>
    			</ss:condition>
    			<ss:condition rescode="SoftwareApply" optcode="UPDATE||DELETE">
    			<th align="center" width="10%">操作</th>
    			</ss:condition>
    		</tr>
    	</thead>
    	<tbody>
    		<s:set name="yearflag" value=""></s:set>
    		<s:iterator value="data">
    		<% if((rowColor++ %2)==0){ %>
    		<tr class="data_tr_bgcs1" onmouseover="changeRowColor(this)" onmouseout="resumeRowColor(this,<%=rowColor%2 %>)">
    		<%}else{ %>
    		<tr class="data_tr_bgcs2" onmouseover="changeRowColor(this)" onmouseout="resumeRowColor(this,<%=rowColor%2 %>)">
    		<%} %>
			
				<s:if test="belongYear!=#yearflag">
    			<s:set name="yearflag" value="belongYear"></s:set>
    				<td colspan="7" class="yearTDStyle">&nbsp;&nbsp;<s:property value="belongYear"/>年</td>
    				</tr>
    				<% rowNo=1;
    				if((rowColor++ %2)==0){ %>
    					<tr class="data_tr_bgcs1" onmouseover="changeRowColor(this)" onmouseout="resumeRowColor(this,<%=rowColor%2 %>)">
    				<%}else{ %>
    					<tr class="data_tr_bgcs2" onmouseover="changeRowColor(this)" onmouseout="resumeRowColor(this,<%=rowColor%2 %>)">
    				<%} %>
    			</s:if>
    			
    			
    			<s:if test="states == 1">
    				<td align="center" class="data_show_color1">
    			</s:if>
    			<s:elseif test="states == 2">
    				<td align="center" class="data_show_color2">
    			</s:elseif>
    			<s:elseif test="states == 3">
    				<td align="center" class="data_show_color3">
    			</s:elseif>
    			<s:else>
    				<td align="center">
    			</s:else>
    			<span><%=rowNo++ %></span>
    			</td>
    			
    			
    			
    			
    			<s:if test="states == 1">
    				<td align="center" class="data_show_color1">
    			</s:if>
    			<s:elseif test="states == 2">
    				<td align="center" class="data_show_color2">
    			</s:elseif>
    			<s:elseif test="states == 3">
    				<td align="center" class="data_show_color3">
    			</s:elseif>
    			<s:else>
    				<td align="center">
    			</s:else>
    			<a href='javascript:lookView(<s:property value="id"/>)' style="cusor:hand">
    				<s:property value="reportName"/>
    			</a>
    			</td>
    			
    			
    			<s:if test="states == 1">
    				<td align="center" class="data_show_color1">
    			</s:if>
    			<s:elseif test="states == 2">
    				<td align="center" class="data_show_color2">
    			</s:elseif>
    			<s:elseif test="states == 3">
    				<td align="center" class="data_show_color3">
    			</s:elseif>
    			<s:else>
    				<td align="center">
    			</s:else>
    			<span><s:property value="submitPerson"/></span>
    			</td>
    			
    			<s:if test="states == 1">
    				<td align="center" class="data_show_color1">
    			</s:if>
    			<s:elseif test="states == 2">
    				<td align="center" class="data_show_color2">
    			</s:elseif>
    			<s:elseif test="states == 3">
    				<td align="center" class="data_show_color3">
    			</s:elseif>
    			<s:else>
    				<td align="center">
    			</s:else>
    			<span><s:property value="author"/></span>
    			</td>
    			
    			
    			<s:if test="states == 1">
    				<td align="center" class="data_show_color1">
    			</s:if>
    			<s:elseif test="states == 2">
    				<td align="center" class="data_show_color2">
    			</s:elseif>
    			<s:elseif test="states == 3">
    				<td align="center" class="data_show_color3">
    			</s:elseif>
    			<s:else>
    				<td align="center">
    			</s:else>
    			<span><s:date name="submitDate" format="yyyy-MM-dd"/></span>
    			</td>
    			
    			
    			<ss:condition rescode="SoftwareApply" optcode="PRINT||GLOBAL">
    				<s:if test="states == 1">
	    				<td align="center" class="data_show_color1">
	    			</s:if>
	    			<s:elseif test="states == 2">
	    				<td align="center" class="data_show_color2">
	    			</s:elseif>
	    			<s:elseif test="states == 3">
	    				<td align="center" class="data_show_color3">
	    			</s:elseif>
	    			<s:else>
	    				<td align="center">
	    			</s:else>
	    			<span><s:property value="sentDepName"/></span></td>
    			</ss:condition>
    			<ss:condition rescode="SoftwareApply" optcode="UPDATE||DELETE">
	    			<s:if test="states == 1">
	    				<td align="center" class="data_show_color1">
	    			</s:if>
	    			<s:elseif test="states == 2">
	    				<td align="center" class="data_show_color2">
	    			</s:elseif>
	    			<s:elseif test="states == 3">
	    				<td align="center" class="data_show_color3">
	    			</s:elseif>
	    			<s:else>
	    				<td align="center">
	    			</s:else>
	    				<ss:condition rescode="SoftwareApply" optcode="UPDATE">
							<a href="javascript:goUpdate(<s:property value="id"/>)">[修改]</a>
						</ss:condition>
	    				<ss:condition rescode="SoftwareApply" optcode="DELETE">
						<a href="javascript:del(<s:property value="id"/>)">[删除]</a>
						</ss:condition>
	    			</td>
				</ss:condition>
    			
    		 </tr>
    		</s:iterator>
    		
    		<tr class="data_tr_bgcs1">
    			<td colspan="7" style="color: black;text-align: left;">
    			备注：
    			<br/>

				&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;处于<span class="data_show_color1">申请中</span>状态的成果以<span class="data_show_color1">蓝色</span>显示
				<br/>
				
				&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;处于<span class="data_show_color2">已获批</span>状态的成果以<span class="data_show_color2">绿色</span>显示
				<br/>
				
				&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;处于<span class="data_show_color3">未获批</span>状态的成果以<span class="data_show_color3">灰色</span>显示
    			</td>
    		</tr>
    		
    		
    	</tbody>
		<tfoot>
    	<s:if test="pagePosition.toLowerCase().equals('buttom') || pagePosition.toLowerCase().equals('all')">
    		<tr class="dataList_pageForm_style">
    			<td colspan="20">
    				<ss:page value="pageForm"></ss:page>
    			</td>
    		</tr>
    		</s:if>
    	</tfoot>
    </table>